
function LandCfgVoData() {
    this.id;
    this.stageId;
    this.pointX;
    this.pointY;
    this.pointZ;
    this.type;
    this.state;
};
LandCfgVoData.prototype.setValue = function (mData) {
    this.id = mData.id;
    this.stageId = mData.stageId;
    this.pointX = mData.pointX;
    this.pointY = mData.pointY;
    this.pointZ = mData.pointZ;
    this.type = mData.type;
    this.state = mData.state;
};

var LandCfgData = {
    dataList: null,
    filePath: null,
    init: function () {
        this.dataList = new window.dictionary();
        this.filePath = window.Constant.RootPath.CONFIG_ROOT_PATH + "Land";
        // this.filePath = "configs/Land";
        // this.dataDic=window.data.ButtleData.dataDiction;
        window.cc.loader.loadRes(this.filePath, (function (err, array) {
            if (err) {
                console.log("错误信息:" + err);
                return;
            }
            var arrs = array.json;
            for (var i = 0; i < arrs.length; i++) {
                var mData = arrs[i];
                var mVoData = new LandCfgVoData();
                mVoData.setValue(mData);
                this.dataList.add(mVoData.id, mVoData);
            }

        }).bind(this));
    },
    getLandCfgData: function () {
        return this.dataList;
    }
}
module.exports = LandCfgData;

